3.3 \(\int x (a+b x) \cosh (c+d x) \, dx\)

Optimal. Leaf size=64 \[ -\frac {a \cosh (c+d x)}{d^2}+\frac {a x \sinh (c+d x)}{d}+\frac {2 b \sinh (c+d x)}{d^3}-\frac {2 b x \cosh (c+d x)}{d^2}+\frac {b x^2 \sinh (c+d x)}{d} \]

[Out]

-a*cosh(d*x+c)/d^2-2*b*x*cosh(d*x+c)/d^2+2*b*sinh(d*x+c)/d^3+a*x*sinh(d*x+c)/d+b*x^2*sinh(d*x+c)/d

________________________________________________________________________________________

Rubi [A]  time = 0.11, antiderivative size = 64, normalized size of antiderivative = 1.00, number of steps used = 7, number of rules used = 4, integrand size = 13, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.308, Rules used = {6742, 3296, 2638, 2637} \[ -\frac {a \cosh (c+d x)}{d^2}+\frac {a x \sinh (c+d x)}{d}+\frac {2 b \sinh (c+d x)}{d^3}-\frac {2 b x \cosh (c+d x)}{d^2}+\frac {b x^2 \sinh (c+d x)}{d} \]

Antiderivative was successfully verified.

[In]

Int[x*(a + b*x)*Cosh[c + d*x],x]

[Out]

-((a*Cosh[c + d*x])/d^2) - (2*b*x*Cosh[c + d*x])/d^2 + (2*b*Sinh[c + d*x])/d^3 + (a*x*Sinh[c + d*x])/d + (b*x^
2*Sinh[c + d*x])/d

Rule 2637

Int[sin[Pi/2 + (c_.) + (d_.)*(x_)], x_Symbol] :> Simp[Sin[c + d*x]/d, x] /; FreeQ[{c, d}, x]

Rule 2638

Int[sin[(c_.) + (d_.)*(x_)], x_Symbol] :> -Simp[Cos[c + d*x]/d, x] /; FreeQ[{c, d}, x]

Rule 3296

Int[((c_.) + (d_.)*(x_))^(m_.)*sin[(e_.) + (f_.)*(x_)], x_Symbol] :> -Simp[((c + d*x)^m*Cos[e + f*x])/f, x] +
Dist[(d*m)/f, Int[(c + d*x)^(m - 1)*Cos[e + f*x], x], x] /; FreeQ[{c, d, e, f}, x] && GtQ[m, 0]

Rule 6742

Int[u_, x_Symbol] :> With[{v = ExpandIntegrand[u, x]}, Int[v, x] /; SumQ[v]]

Rubi steps

\begin {align*} \int x (a+b x) \cosh (c+d x) \, dx &=\int \left (a x \cosh (c+d x)+b x^2 \cosh (c+d x)\right ) \, dx\\ &=a \int x \cosh (c+d x) \, dx+b \int x^2 \cosh (c+d x) \, dx\\ &=\frac {a x \sinh (c+d x)}{d}+\frac {b x^2 \sinh (c+d x)}{d}-\frac {a \int \sinh (c+d x) \, dx}{d}-\frac {(2 b) \int x \sinh (c+d x) \, dx}{d}\\ &=-\frac {a \cosh (c+d x)}{d^2}-\frac {2 b x \cosh (c+d x)}{d^2}+\frac {a x \sinh (c+d x)}{d}+\frac {b x^2 \sinh (c+d x)}{d}+\frac {(2 b) \int \cosh (c+d x) \, dx}{d^2}\\ &=-\frac {a \cosh (c+d x)}{d^2}-\frac {2 b x \cosh (c+d x)}{d^2}+\frac {2 b \sinh (c+d x)}{d^3}+\frac {a x \sinh (c+d x)}{d}+\frac {b x^2 \sinh (c+d x)}{d}\\ \end {align*}

________________________________________________________________________________________

Mathematica [A]  time = 0.10, size = 45, normalized size = 0.70 \[ \frac {\left (a d^2 x+b \left (d^2 x^2+2\right )\right ) \sinh (c+d x)-d (a+2 b x) \cosh (c+d x)}{d^3} \]

Antiderivative was successfully verified.

[In]

Integrate[x*(a + b*x)*Cosh[c + d*x],x]

[Out]

(-(d*(a + 2*b*x)*Cosh[c + d*x]) + (a*d^2*x + b*(2 + d^2*x^2))*Sinh[c + d*x])/d^3

________________________________________________________________________________________

fricas [A]  time = 0.65, size = 48, normalized size = 0.75 \[ -\frac {{\left (2 \, b d x + a d\right )} \cosh \left (d x + c\right ) - {\left (b d^{2} x^{2} + a d^{2} x + 2 \, b\right )} \sinh \left (d x + c\right )}{d^{3}} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(x*(b*x+a)*cosh(d*x+c),x, algorithm="fricas")

[Out]

-((2*b*d*x + a*d)*cosh(d*x + c) - (b*d^2*x^2 + a*d^2*x + 2*b)*sinh(d*x + c))/d^3

________________________________________________________________________________________

giac [A]  time = 0.12, size = 79, normalized size = 1.23 \[ \frac {{\left (b d^{2} x^{2} + a d^{2} x - 2 \, b d x - a d + 2 \, b\right )} e^{\left (d x + c\right )}}{2 \, d^{3}} - \frac {{\left (b d^{2} x^{2} + a d^{2} x + 2 \, b d x + a d + 2 \, b\right )} e^{\left (-d x - c\right )}}{2 \, d^{3}} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(x*(b*x+a)*cosh(d*x+c),x, algorithm="giac")

[Out]

1/2*(b*d^2*x^2 + a*d^2*x - 2*b*d*x - a*d + 2*b)*e^(d*x + c)/d^3 - 1/2*(b*d^2*x^2 + a*d^2*x + 2*b*d*x + a*d + 2
*b)*e^(-d*x - c)/d^3

________________________________________________________________________________________

maple [A]  time = 0.05, size = 122, normalized size = 1.91 \[ \frac {\frac {b \left (\left (d x +c \right )^{2} \sinh \left (d x +c \right )-2 \left (d x +c \right ) \cosh \left (d x +c \right )+2 \sinh \left (d x +c \right )\right )}{d}-\frac {2 b c \left (\left (d x +c \right ) \sinh \left (d x +c \right )-\cosh \left (d x +c \right )\right )}{d}+a \left (\left (d x +c \right ) \sinh \left (d x +c \right )-\cosh \left (d x +c \right )\right )+\frac {b \,c^{2} \sinh \left (d x +c \right )}{d}-a c \sinh \left (d x +c \right )}{d^{2}} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(x*(b*x+a)*cosh(d*x+c),x)

[Out]

1/d^2*(b/d*((d*x+c)^2*sinh(d*x+c)-2*(d*x+c)*cosh(d*x+c)+2*sinh(d*x+c))-2*b*c/d*((d*x+c)*sinh(d*x+c)-cosh(d*x+c
))+a*((d*x+c)*sinh(d*x+c)-cosh(d*x+c))+b*c^2/d*sinh(d*x+c)-a*c*sinh(d*x+c))

________________________________________________________________________________________

maxima [B]  time = 0.39, size = 160, normalized size = 2.50 \[ -\frac {1}{12} \, d {\left (\frac {3 \, {\left (d^{2} x^{2} e^{c} - 2 \, d x e^{c} + 2 \, e^{c}\right )} a e^{\left (d x\right )}}{d^{3}} + \frac {3 \, {\left (d^{2} x^{2} + 2 \, d x + 2\right )} a e^{\left (-d x - c\right )}}{d^{3}} + \frac {2 \, {\left (d^{3} x^{3} e^{c} - 3 \, d^{2} x^{2} e^{c} + 6 \, d x e^{c} - 6 \, e^{c}\right )} b e^{\left (d x\right )}}{d^{4}} + \frac {2 \, {\left (d^{3} x^{3} + 3 \, d^{2} x^{2} + 6 \, d x + 6\right )} b e^{\left (-d x - c\right )}}{d^{4}}\right )} + \frac {1}{6} \, {\left (2 \, b x^{3} + 3 \, a x^{2}\right )} \cosh \left (d x + c\right ) \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(x*(b*x+a)*cosh(d*x+c),x, algorithm="maxima")

[Out]

-1/12*d*(3*(d^2*x^2*e^c - 2*d*x*e^c + 2*e^c)*a*e^(d*x)/d^3 + 3*(d^2*x^2 + 2*d*x + 2)*a*e^(-d*x - c)/d^3 + 2*(d
^3*x^3*e^c - 3*d^2*x^2*e^c + 6*d*x*e^c - 6*e^c)*b*e^(d*x)/d^4 + 2*(d^3*x^3 + 3*d^2*x^2 + 6*d*x + 6)*b*e^(-d*x
- c)/d^4) + 1/6*(2*b*x^3 + 3*a*x^2)*cosh(d*x + c)

________________________________________________________________________________________

mupad [B]  time = 0.92, size = 62, normalized size = 0.97 \[ \frac {b\,x^2\,\mathrm {sinh}\left (c+d\,x\right )+a\,x\,\mathrm {sinh}\left (c+d\,x\right )}{d}-\frac {a\,\mathrm {cosh}\left (c+d\,x\right )+2\,b\,x\,\mathrm {cosh}\left (c+d\,x\right )}{d^2}+\frac {2\,b\,\mathrm {sinh}\left (c+d\,x\right )}{d^3} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(x*cosh(c + d*x)*(a + b*x),x)

[Out]

(b*x^2*sinh(c + d*x) + a*x*sinh(c + d*x))/d - (a*cosh(c + d*x) + 2*b*x*cosh(c + d*x))/d^2 + (2*b*sinh(c + d*x)
)/d^3

________________________________________________________________________________________

sympy [A]  time = 0.49, size = 82, normalized size = 1.28 \[ \begin {cases} \frac {a x \sinh {\left (c + d x \right )}}{d} - \frac {a \cosh {\left (c + d x \right )}}{d^{2}} + \frac {b x^{2} \sinh {\left (c + d x \right )}}{d} - \frac {2 b x \cosh {\left (c + d x \right )}}{d^{2}} + \frac {2 b \sinh {\left (c + d x \right )}}{d^{3}} & \text {for}\: d \neq 0 \\\left (\frac {a x^{2}}{2} + \frac {b x^{3}}{3}\right ) \cosh {\relax (c )} & \text {otherwise} \end {cases} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(x*(b*x+a)*cosh(d*x+c),x)

[Out]

Piecewise((a*x*sinh(c + d*x)/d - a*cosh(c + d*x)/d**2 + b*x**2*sinh(c + d*x)/d - 2*b*x*cosh(c + d*x)/d**2 + 2*
b*sinh(c + d*x)/d**3, Ne(d, 0)), ((a*x**2/2 + b*x**3/3)*cosh(c), True))

________________________________________________________________________________________